package com.yxy.ms.manager.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.github.pagehelper.Page;
import com.yxy.ms.manager.dao.JobDetailMapper;
import com.yxy.ms.manager.dao.JobTriggerMapper;
import com.yxy.ms.manager.entity.po.JobDetail;
import com.yxy.ms.manager.entity.po.JobTrigger;
import com.yxy.ms.manager.service.JobService;

/**
 * 
 * @author yangcheng6327
 * @date 2019/11/25
 */
@Service("jobService")
public class JobServiceImpl implements JobService {

    @Autowired
    JobDetailMapper jobDetailMapper;
    @Autowired
    JobTriggerMapper jobTriggerMapper;

    @Override
    public Page<JobDetail> listQuartzEntity(Map<String, Object> params) {
        return jobDetailMapper.findAll(params);
    }

    @Override
    public Page<JobTrigger> findJobTriggers(Map<String, Object> params) {
        return jobTriggerMapper.findAll(params);
    }

    @Override
    public List<String> loadShedNames() {
        return jobDetailMapper.loadShedNames();
    }

    @Override
    public List<String> loadJobStatus() {
        return jobTriggerMapper.loadJobStatus();
    }

    @Override
    public List<String> loadJobGrops() {
        return jobDetailMapper.loadJobGrops();
    }

}
